<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div class="border"></div>
    <div class="kong"></div>
</body>
<style>
    .border {
        width: 0;
        height: 0;
        border-top: 100px solid transparent;
        border-left: 100px solid transparent;
        border-right: 100px solid transparent;
        border-bottom: 100px solid blueviolet;
        position: relative;
    }
    .kong{
        width: 0;
        height: 0;
        border-top: 50px solid transparent;
        border-left: 50px solid transparent;
        border-right: 50px solid transparent;
        border-bottom: 50px solid rgb(118, 86, 147);
        position: absolute;
        top: 0;
        left: 0;
        transition: transform(-50%,-50%);
    }
</style>

</html>